package com.newzqxq.koalamoney.model;

import com.newzqxq.koalamoney.entity.RegisterBean;
import com.newzqxq.koalamoney.net.AppService;

import javax.inject.Inject;

import happyloan.core.EventBusUtil;

/**
 * Created by ZQXQ-Developer on 2017/7/26.
 */

public class ForgetPwdModel {
    private AppService service;

    @Inject
    ForgetPwdModel(AppService service) {
        this.service = service;
    }

    public void forgetPassword(String phone, String sms_code, String new_login_pwd) {
        EventBusUtil<Void> util = new EventBusUtil<>();
        util.sendEvent4Call(service.forgetpwd(phone, sms_code, new_login_pwd));
    }

    public void sendCode(String phone, int type) {
        EventBusUtil<String> util = new EventBusUtil<>();
        util.sendEvent4Call(service.sendCode(phone, type));
    }
}
